<script setup>
import { RouterView } from 'vue-router'
</script>

<template>
  <RouterView />
</template>

<script>
import { debounce } from '@/utils/ruoyi.js'
export default {
  created() {
    const fnc = debounce((event) => {
      let u = navigator.userAgent
      if (u.indexOf('iPhone') > -1) {
        event.preventDefault() // 阻止默认的滚动行为
      }
    }, 200)
    document.addEventListener('touchmove', fnc, {
      passive: false,
    })
  },
}
</script>

<style>
body,
html {
  overscroll-behavior: none; /* 禁用橡皮筋效果 */
}
</style>
